#调用此函数需传入protections，用于设置不会被删除的NBT，格式为字符串列表，字符串内容为NBT路径

#从列表分离
$data modify storage dab:register RDDKeyKiller.protections set value $(protections)
    #默认除外
    data modify storage dab:register RDDKeyKiller.protections append value "type"
    data modify storage dab:register RDDKeyKiller.protections append value "id"
function dab:system/register/.redundant_key_killer/list_to_id

#删除冗余
function dab:system/register/.redundant_key_killer/reloop_remove_rdd {index:-1}
execute unless data storage dab:register RDDKeyKiller.temp run data modify storage dab:register RDDKeyKiller.temp set value {}
data modify storage dab:register parser set from storage dab:register RDDKeyKiller.temp

data remove storage dab:register RDDKeyKiller